<!DOCTYPE html>
<html lang="en" class="no-js"> <!--<![endif]-->
<!-- BEGIN HEAD -->
<head>
   <meta charset="utf-8" />
   <title><?php echo PROJECT_NAME; ?></title>
   <meta http-equiv="X-UA-Compatible" content="IE=edge">
   <meta content="width=device-width, initial-scale=1.0" name="viewport" />
   <meta content="" name="description" />
   <meta content="" name="author" />
   <meta name="MobileOptimized" content="320">
   <!-- BEGIN GLOBAL MANDATORY STYLES -->          
   <link href="<?php echo base_url(); ?>../assets/modules/metronic/plugins/font-awesome/css/font-awesome.min.css" rel="stylesheet" type="text/css"/>
   <link href="<?php echo base_url(); ?>../assets/modules/metronic/plugins/bootstrap/css/bootstrap.min.css" rel="stylesheet" type="text/css"/>
   <link href="<?php echo base_url(); ?>../assets/modules/metronic/plugins/uniform/css/uniform.default.css" rel="stylesheet" type="text/css"/>
   <!-- END GLOBAL MANDATORY STYLES -->
   <!-- BEGIN THEME STYLES --> 
   <link href="<?php echo base_url(); ?>../assets/modules/metronic/css/style-metronic.css" rel="stylesheet" type="text/css"/>
   <link href="<?php echo base_url(); ?>../assets/modules/metronic/css/style.css" rel="stylesheet" type="text/css"/>
   <link href="<?php echo base_url(); ?>../assets/modules/metronic/css/style-responsive.css" rel="stylesheet" type="text/css"/>
   <link href="<?php echo base_url(); ?>../assets/modules/metronic/css/plugins.css" rel="stylesheet" type="text/css"/>
   <link href="<?php echo base_url(); ?>../assets/modules/metronic/css/themes/default.css" rel="stylesheet" type="text/css" id="style_color"/>
   <link href="<?php echo base_url(); ?>../assets/modules/metronic/css/custom.css" rel="stylesheet" type="text/css"/>
   <link href="<?php echo base_url(); ?>../assets/css/printstyle.css" rel="stylesheet" type="text/css"/>
   <!-- END THEME STYLES -->
   <link rel="shortcut icon" href="favicon.ico" />
   
   <link rel="stylesheet" type="text/css" href="<?php echo base_url(); ?>../assets/modules/metronic/plugins/bootstrap-daterangepicker/daterangepicker-bs3.css" /><link rel="stylesheet" type="text/css" href="<?php echo base_url(); ?>../assets/modules/metronic/plugins/jquery-ui/jquery-ui-1.10.3.custom.min.css" />
    
   <!-- BEGIN JAVASCRIPTS(Load javascripts at bottom, this will reduce page load time) -->
   <!-- BEGIN CORE PLUGINS -->   
   <!--[if lt IE 9]>
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/respond.min.js"></script>
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/excanvas.min.js"></script> 
   <![endif]-->   
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/jquery-1.10.2.min.js" type="text/javascript"></script>
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/jquery-migrate-1.2.1.min.js" type="text/javascript"></script>
   <!-- IMPORTANT! Load jquery-ui-1.10.3.custom.min.js before bootstrap.min.js to fix bootstrap tooltip conflict with jquery ui tooltip -->
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/jquery-ui/jquery-ui-1.10.3.custom.min.js" type="text/javascript"></script>      
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/bootstrap/js/bootstrap.min.js" type="text/javascript"></script>
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/bootstrap-hover-dropdown/twitter-bootstrap-hover-dropdown.min.js" type="text/javascript" ></script>
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/jquery-slimscroll/jquery.slimscroll.min.js" type="text/javascript"></script>
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/jquery.blockui.min.js" type="text/javascript"></script>  
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/jquery.cookie.min.js" type="text/javascript"></script>
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/uniform/jquery.uniform.min.js" type="text/javascript" ></script>
   <!-- END CORE PLUGINS -->
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/scripts/app.js"></script>      
 
	<?php echo css_asset("unugrid.css","unugrid"); ?>
	<?php echo js_asset("unugrid.js","unugrid"); ?>
	<?php echo js_asset("jquery.formatCurrency-1.4.0.js"); ?>
	
   <script type="text/javascript" src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/select2/select2.min.js"></script>
	<link rel="stylesheet" type="text/css" href="<?php echo base_url(); ?>../assets/modules/metronic/plugins/select2/select2_metro.css" />
   
   <link rel="stylesheet" type="text/css" href="<?php echo base_url(); ?>../assets/modules/metronic/plugins/bootstrap-datepicker/css/datepicker.css" />
   <script type="text/javascript" src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/bootstrap-datepicker/js/bootstrap-datepicker.js"></script>
   <script type="text/javascript" src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/bootstrap-daterangepicker/moment.min.js"></script>
   <script type="text/javascript" src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/bootstrap-daterangepicker/daterangepicker.js"></script> 
   
	<!-- script type="text/javascript" src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/select2/select2.min.js"></script>
   <script type="text/javascript" src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/data-tables/jquery.dataTables.js"></script>
   <script type="text/javascript" src="<?php echo base_url(); ?>../assets/modules/metronic/plugins/data-tables/DT_bootstrap.js"></script>
   <script src="<?php echo base_url(); ?>../assets/modules/metronic/scripts/table-managed.js"></script -->
	
	<?php echo js_asset("script.js"); ?>
	<script>
      jQuery(document).ready(function() {    
         App.init();
      });
   </script>
   <!-- END JAVASCRIPTS -->

</head>
<!-- END HEAD -->
<!-- BEGIN BODY -->
<body class="page-header-fixed page-sidebar-fixed">
   <!-- BEGIN HEADER -->   
   <div class="header navbar navbar-inverse navbar-fixed-top">
      <!-- BEGIN TOP NAVIGATION BAR -->
      <div class="header-inner">
         <!-- BEGIN LOGO --> 
         <a class="navbar-brand" style="width:50%" href="#">
         &nbsp;<?php echo PROJECT_NAME; ?>
         </a>
         <!-- END LOGO -->
         <!-- BEGIN RESPONSIVE MENU TOGGLER --> 
         <a href="javascript:;" class="navbar-toggle" data-toggle="collapse" data-target=".navbar-collapse">
         <img src="<?php echo base_url(); ?>../assets/modules/metronic/img/menu-toggler.png" alt="" />
         </a> 
         <!-- END RESPONSIVE MENU TOGGLER -->
         <!-- BEGIN TOP NAVIGATION MENU -->
         <ul class="nav navbar-nav pull-right">
            
            <!-- BEGIN USER LOGIN DROPDOWN -->
            <li class="dropdown user">
               <a href="#" class="dropdown-toggle" data-toggle="dropdown" data-hover="dropdown" data-close-others="true">
               <img alt="" src="<?php echo base_url(); ?>../assets/modules/metronic/img/guest.png"/>
               <span class="username">
			   <?php if (@$_SESSION[SESSION_USERID] != ""){
					echo @$_SESSION[SESSION_USERNAME];
				}else{
				?>
			   Guest / Tamu
			   <?php } ?>
			   </span>
               <i class="icon-angle-down"></i>
               </a>
			   
			   <?php if (@$_SESSION[SESSION_USERID] != ""){ ?>
               <ul class="dropdown-menu"  >
					<li><a href="#" data-url="c_settings" class="menu" data-param=""><i class="icon-wrench"></i> Setting</a>
					<li><a href="<?php echo base_url("c_login/logout");?>"><i class="icon-key"></i> Log Out</a>
                  </li>
				<?php }else{
				?>
               <ul class="dropdown-menu extended" style="padding:10px">
				<!-- BEGIN LOGIN FORM -->
				<div class="login">
				<div class="content">
				<form class="login-form login-navbar"  onSubmit="javascript:return false" >
					<h3 class="form-title">Login </h3>
					<div class="alert alert-error hide">
						<button class="close" data-dismiss="alert"></button>
						<span>Enter any username and password.</span>
					</div>
					<div class="form-group">
						<!--ie8, ie9 does not support html5 placeholder, so we just show field title for that-->
						<label class="control-label visible-ie8 visible-ie9">Username</label>
						<div class="input-icon">
							<i class="icon-user"></i>
							<input class="form-control placeholder-no-fix" type="text" autocomplete="off" placeholder="Username" name="username" id="username" />
						</div>
					</div>
					<div class="form-group">
						<label class="control-label visible-ie8 visible-ie9">Password</label>
						<div class="input-icon">
							<i class="icon-lock"></i>
							<input class="form-control placeholder-no-fix" type="password" autocomplete="off" placeholder="Password" name="password" id="password" />
						</div>
					</div>
					<div class="form-actions">
						<button onSubmit="return False"  type="submit" id="btnlogin" class="btn green pull-right">
						Login <i class="m-icon-swapright m-icon-white"></i>
						</button>            
					</div>
				</form>
				</div>
				</div>
				<!-- END LOGIN FORM --> 
               <?php } ?>
			   </ul>
            </li>
            <!-- END USER LOGIN DROPDOWN -->
         </ul>
         <!-- END TOP NAVIGATION MENU -->
      </div>
      <!-- END TOP NAVIGATION BAR -->
   </div>
   <!-- END HEADER -->
   <div class="clearfix"></div>
   <!-- BEGIN CONTAINER -->   
   <div class="page-container">
      <!-- BEGIN SIDEBAR -->
      <div class="page-sidebar navbar-collapse collapse">
         <!-- BEGIN SIDEBAR MENU -->        
         <ul class="page-sidebar-menu">
            <li>
               <!-- BEGIN SIDEBAR TOGGLER BUTTON -->
                  <div style="background:#fff; opacity:0.7;">
                    <center>
            <img src="<?php echo base_url(); ?>../assets/images/ptpp.jpg" height="100%" width="100%"/>
            </center>
                </div>
               <div class="sidebar-toggler hidden-phone"></div>
               <!-- BEGIN SIDEBAR TOGGLER BUTTON -->
            </li>
            <li>
               <!-- BEGIN RESPONSIVE QUICK SEARCH FORM -->
               <form class="sidebar-search" action="extra_search.html" method="POST">
                  <div class="form-container">
                     <div class="input-box">
                        <a href="javascript:;" class="remove"></a>
                        <input type="text" placeholder="Search..."/>
                        <input type="button" class="submit" value=" "/>
                     </div>
                  </div>
               </form>
               <!-- END RESPONSIVE QUICK SEARCH FORM -->
            </li>
			<?php echo @$menu; ?>
            <!-- li class="start ">
               <a href="index.html">
               <i class="icon-home"></i> 
               <span class="title">Dashboard</span>
               </a>
            </li>
            <li class="active ">
               <a href="javascript:;">
               <i class="icon-cogs"></i> 
               <span class="title">Layouts</span>
               <span class="selected"></span>
               <span class="arrow open"></span>
               </a>
               <ul class="sub-menu">
                  <li >
                     <a href="layout_horizontal_sidebar_menu.html">
                     Horizontal & Sidebar Menu</a>
                  </li>
                  <li >
                     <a href="layout_horizontal_menu1.html">
                     Horizontal Menu 1</a>
                  </li>
                  <li >
                     <a href="layout_horizontal_menu2.html">
                     Horizontal Menu 2</a>
                  </li><li >
                     <a href="layout_disabled_menu.html">
                     Disabled Menu Links</a>
                  </li>
                  <li class="active">
                     <a href="layout_sidebar_fixed.html">
                     Sidebar Fixed Page</a>
                  </li>
               </ul>
            </li>

            <li class="">
               <a href="javascript:;">
               <i class="icon-bookmark-empty"></i> 
               <span class="title">UI Features</span>
               <span class="arrow "></span>
               </a>
               <ul class="sub-menu">
                  <li >
                     <a href="ui_general.html">
                     General</a>
                  </li>
                  <li >
                     <a href="ui_buttons.html">
                     Buttons</a>
                  </li>
                  <li >
                     <a href="ui_typography.html">
                     Typography</a>
                  </li>
               </ul>
            </li>
            <li class="last ">
               <a href="charts.html">
               <i class="icon-bar-chart"></i> 
               <span class="title">Visual Charts</span>
               </a>
            </li -->
         </ul>
         <!-- END SIDEBAR MENU -->
      </div>
      <!-- END SIDEBAR -->
      <!-- BEGIN PAGE -->
      <div class="page-content ">
         <!-- BEGIN SAMPLE PORTLET CONFIGURATION MODAL FORM-->               
         <div class="modal fade" id="portlet-config" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
            <div class="modal-dialog">
               <div class="modal-content">
                  <div class="modal-header">
                     <button type="button" class="close" data-dismiss="modal" aria-hidden="true"></button>
                     <h4 class="modal-title">Modal title</h4>
                  </div>
                  <div class="modal-body">
                     Widget settings form goes here
                  </div>
                  <div class="modal-footer">
                     <button type="button" class="btn blue">Save changes</button>
                     <button type="button" class="btn default" data-dismiss="modal">Close</button>
                  </div>
               </div>
               <!-- /.modal-content -->
            </div>
            <!-- /.modal-dialog -->
         </div>
         <!-- /.modal -->
         <!-- END SAMPLE PORTLET CONFIGURATION MODAL FORM-->
         <!-- BEGIN STYLE CUSTOMIZER -->
         <div class="theme-panel hidden-xs hidden-sm">
            <div class="toggler"></div>
            <div class="toggler-close"></div>
            <div class="theme-options">
               <div class="theme-option theme-colors clearfix">
                  <span>THEME COLOR</span>
                  <ul>
                     <li class="color-black current color-default" data-style="default"></li>
                     <li class="color-blue" data-style="blue"></li>
                     <li class="color-brown" data-style="brown"></li>
                     <li class="color-purple" data-style="purple"></li>
                     <li class="color-grey" data-style="grey"></li>
                     <li class="color-white color-light" data-style="light"></li>
                  </ul>
               </div>
               <div class="theme-option">
                  <span>Layout</span>
                  <select class="layout-option form-control input-small">
                     <option value="fluid" selected="selected">Fluid</option>
                     <option value="boxed">Boxed</option>
                  </select>
               </div>
               <div class="theme-option">
                  <span>Header</span>
                  <select class="header-option form-control input-small">
                     <option value="fixed" selected="selected">Fixed</option>
                     <option value="default">Default</option>
                  </select>
               </div>
               <div class="theme-option">
                  <span>Sidebar</span>
                  <select class="sidebar-option form-control input-small" readonly>
                     <option value="fixed" selected="selected">Fixed</option>
                     <option value="default">Default</option>
                  </select>
               </div>
               <div class="theme-option">
                  <span>Footer</span>
                  <select class="footer-option form-control input-small">
                     <option value="fixed">Fixed</option>
                     <option value="default" selected="selected">Default</option>
                  </select>
               </div>
            </div>
         </div>
         <!-- END BEGIN STYLE CUSTOMIZER -->           
         <!-- BEGIN PAGE HEADER-->
         <div class="row">
            <div class="col-md-12">
               <!-- BEGIN PAGE TITLE & BREADCRUMB-->
               <h3 class="page-title">
                 <small></small>
               </h3>

               <ul class="page-breadcrumb breadcrumb">
                  <li>
                     <i class="icon-home"></i>
                     <a href="index.html">Home</a> 
                     <i class="icon-angle-right"></i>
                  </li>
           
               </ul>
               <!-- END PAGE TITLE & BREADCRUMB-->
            </div>
         </div>
         <!-- END PAGE HEADER-->
         <!-- BEGIN PAGE CONTENT-->
			<div class="row">
				<div class="col-md-12 main">
              		   
                  </div>
               </div>
               <!-- END EXAMPLE TABLE PORTLET-->
			   
            </div>
         </div>
         <!-- END PAGE CONTENT-->
      </div>
      <!-- END PAGE -->    
   </div>
   <!-- END CONTAINER -->
   <!-- BEGIN FOOTER -->
   <div class="footer">
      <div class="footer-inner">
         2013 &copy; <?php echo PROJECT_NAME; ?>.
      </div>
      <div class="footer-tools">
         <span class="go-top">
         <i class="icon-angle-up"></i>
         </span>
      </div>
   </div>
   <!-- END FOOTER -->
 
<script>
		$(document).ready(function(){
			var l_username = $("#username");
			var l_password = $("#password");
			$("#btnlogin").click(function(){
				
				$.ajax({
					url :"<?php echo base_url('c_login/process')?>",
					type:"POST",
					dataType:"JSON",
					data:{
							l_username:l_username.val(),
							l_password:l_password.val()
						 },
					success:function(response){
						// console.log(response);
						if(response.message == "true"){
							window.location = "<?php echo base_url()?>"
						} else {
							alert("Maaf, username atau password anda Salah !");
						}
					}
				});
			});
		
			l_username.keypress(function(e){
				if(e.keyCode == 13){
					$("#btnlogin").click();
				}
			});
			
			l_password.keypress(function(e){
				if(e.keyCode == 13){
					$("#btnlogin").click();
				}
			});
			
		});	
</script>
		
</body>
<!-- END BODY -->
</html>